<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE>
<html>
<head>
<base href="<%=basePath%>" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>欢迎使用网上图书馆系统</title>
<link rel="stylesheet" href="resources/css/index.css" />
<link rel="stylesheet" href="resources/css/jPages.css" />
<link rel="stylesheet" href="resources/css/animate.css" />
<script type="text/javascript" src="resources/js/jquery.js"></script>
<script type="text/javascript" src="resources/js/jPages.js"></script>
</head>
<body>
	<div id="templatemo_container">
		<div id="templatemo_banner"></div>
		<!-- end of banner -->

		<div id="templatemo_menu">
			<ul>
				<li><a href="index">主页</a></li>
				<li><a href="book">图书信息查询</a></li>
				<li><a href="user">用户信息查询</a></li>
				<li><a href="signUp">用户注册</a></li>
			</ul>
		</div>

		<div id="templatmeo_content_bottom">
			<div>
				<h1>用户名：${user.username}&nbsp;&nbsp;&nbsp;&nbsp;<a href="logout">点此注销</a></h1>
				<br>
				<h2>
					<span>学生学号：${user.stuId}</span>&nbsp;&nbsp;&nbsp; <span>学生ID：${user.id}</span>&nbsp;&nbsp;&nbsp;
					<br> <br>
					<hr>
				</h2>
				<br>
				<h1>已借的书：</h1>
				<br>
				<div id="books" style="font-size: 20px">
					<c:forEach items="${user.books}" var="book">
						<div>
							<a href="book/${book.id}"><span>书名:${book.bookname}</span>&nbsp;&nbsp;&nbsp;<span>作者:${book.author}</span>&nbsp;&nbsp;&nbsp;<span>图书编号:${book.bookindex}</span>&nbsp;&nbsp;&nbsp;
							<span>出版日期:${book.publicDate}</span>
							</a>&nbsp;&nbsp;&nbsp;<button onclick="window.location.href='book/return/${book.id}'" >点此还书</button><br> <br>
						</div>
					</c:forEach>
				</div>
				<div class="holder"></div>
			</div>
			<br> <br>

			<div class="margin_bottom_40 b_bottom"></div>
			<div class="margin_bottom_30"></div>

			<div id="templatemo_footer">

				<ul class="footer_list">
					<li><a href="index">主页</a></li>
					<li><a href="book" >图书信息查询</a></li>
					<li><a href="user" class="current">用户信息查询</a></li>
					<li><a href="signUp">用户注册</a></li>
				</ul>

				<div class="margin_bottom_10"></div>

				Copyright © 2024 <a href="http://www.zjut.edu.cn/">浙江工业大学</a> |
				Designed by 李德建

				<div class="margin_bottom_20"></div>
			</div>

			<div class="cleaner"></div>
		</div>
		<!-- end of content bottom -->
		<script type="text/javascript">
			$("div.holder").jPages({
				containerID : "books",
				previous : "上一页",
				next : "下一页",
				perPage : 10,
				delay : 10
			});
		</script>
	</div>
</body>